package com.cn.aam.checaiduo.ui.me.adapter;

import android.content.Context;
import android.graphics.Color;
import android.view.View;
import android.widget.TextView;

import com.cn.aam.checaiduo.R;
import com.cn.aam.checaiduo.base.adapter.BaseRecycerAdapter;
import com.cn.aam.checaiduo.base.adapter.holder.BaseRecyclerViewHolder;
import com.cn.aam.checaiduo.bean.me.WithDrawB;

import butterknife.BindView;

/**
 * monker on 2017/5/26.
 */

public class WithdrawRecordAdapter extends BaseRecycerAdapter<WithDrawB> {


    public WithdrawRecordAdapter(Context mContext) {
        super(mContext);
    }

    @Override
    protected BaseRecyclerViewHolder getViewHolder(View picNewsView) {
        return new WithdrawHolder(picNewsView);
    }

    @Override
    protected int getItemLayoutRes() {
        return R.layout.list_item_recharge;
    }

    @Override
    protected void ItemVIewChange(BaseRecyclerViewHolder recyclerholder, int position) {
        WithdrawHolder holder = (WithdrawHolder) recyclerholder;
        holder.tvNum.setText(getItem(position).getAmount());
        holder.tvTime.setText(getItem(position).getCreated_time());
        holder.tvFinalResult.setText("提现成功");
        holder.tvNum.setTextColor(Color.parseColor("#605F87"));
    }

    class WithdrawHolder extends BaseRecyclerViewHolder {
        @BindView(R.id.tv_final_result)
        TextView tvFinalResult;
        @BindView(R.id.tv_num)
        TextView tvNum;
        @BindView(R.id.tv_time)
        TextView tvTime;

        public WithdrawHolder(View itemView) {
            super(itemView);
        }
    }
}
